<template>
  <BasicModal ref="basicModal" v-bind="$attrs" @register="registerModal" destroyOnClose title="打印" :width="800">
    <JmReport v-if="assetId" chartId="890459757303480320" :params="{ assetId }" />
  </BasicModal>
</template>

<script lang="ts" setup>
  import { ref } from 'vue';
  import { BasicModal, useModalInner } from '/@/components/Modal';
  import JmReport from '/@/components/JmReport/index.vue';
  import { useI18n } from '/@/hooks/web/useI18n';
  const { t, isCN } = useI18n('common');
  // Emits声明
  const emit = defineEmits(['register', 'success']);

  const assetId = ref('');
  const [registerModal] = useModalInner(async (data) => {
    //重置表单
    assetId.value = data.assetId;
    console.log(data, 'datadata');
  });
</script>

<style lang="less" scoped>
  /** 时间和数字输入框样式 */
  :deep(.ant-input-number) {
    width: 100%;
  }

  :deep(.ant-calendar-picker) {
    width: 100%;
  }
</style>
